<template>
  <div>
    <h2>{{$store.state.count}}</h2>
    <button @click="increment">+1</button>
    <button @click="$store.dispatch('decrementAction')">-1</button>
    <button @click="$store.dispatch('updateStateAction', '200')">200</button>
  </div>
   <hr>
    <button @click="incrementAction">+1</button>
     <button @click="decrementAction">-1</button>
    <button @click="updateStateAction(200)">200</button>
</template>

<script>
import {mapActions} from 'vuex'
export default {
  methods: {
    // increment() {
    //   this.$store.dispatch('incrementAction')
    // },
    ...mapActions(['decrementAction','incrementAction','updateStateAction'])
  },
};
</script>

<style lang="scss" scoped>
</style>